export default {
  props: {
    to: { type: String, require: true },
    tag: { type: String, default: "a" }
  },
  methods: {
    handler() {
      // 路由跳转
      this.$router.push(this.to);
    }
  },
  render(h) {
    return <a onClick={this.handler} style={{ cursor: "pointer" }}>{this.$slots.default}</a>
  }
}
